cmake_minimum_required(VERSION 3.10)
project(ZMQ_IPC_Delay)

set(CMAKE_CXX_STANDARD 11)

# Find the ZeroMQ package
find_package(PkgConfig REQUIRED)
pkg_check_modules(PC_ZMQ REQUIRED libzmq)
find_path(ZMQ_INCLUDE_DIR zmq.hpp)
find_library(ZMQ_LIBRARY NAMES zmq)

# Include the directories
include_directories(${ZMQ_INCLUDE_DIR})

# Add executable targets
add_executable(sender sender.cpp)
add_executable(receiver receiver.cpp)

# Link the ZeroMQ library
target_link_libraries(sender ${ZMQ_LIBRARY})
target_link_libraries(receiver ${ZMQ_LIBRARY})
